package top.leyi.IService;

import top.leyi.entity.Talk.SimpleTalk;
import top.leyi.entity.Talk.Talk;
import top.leyi.entity.pushAndColle.Push;
import top.leyi.entity.user.User;
import top.leyi.exception.TalkNotFoundException;

import java.util.List;
import java.util.Map;

public interface IPushService {
    /**
     * @desc 查询个人通知
     * @param user
     * @return
     */
    public Map<String, List<Push>> getAllPush(User user);

    /**
     * @desc 查询个人通知
     * @param user
     * @return
     */
    public  List<SimpleTalk> getSysPush(int id);
    /**
     * @desc 添加个人通知
     * @param user
     * @return
     */
    public void addOnePush( Talk talk)  throws TalkNotFoundException;
    /**
     * @desc 移除个人通知
     * @param user
     * @return
     */
    public void removePush(Push push, User user);


    /**
     * @添加一个单播消息
     * @param 通知内容
     * @param 通知方
     * @param 被通知方
     * @throws TalkNotFoundException
     */
    public void addOnePush( Talk talk , int destId)  throws TalkNotFoundException;
}
